package com.sky.controller;

import com.sky.dto.SmsSpuBoundsDTO;
import com.sky.service.SmsSpuBoundsService;
import com.sky.utils.R;
import jakarta.annotation.Resource;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/spuBound")
public class SmsSpuBoundsController {

    @Resource
    private SmsSpuBoundsService smsSpuBoundsService;

    @PostMapping("/add")
    public R addSpuBounds(@RequestBody SmsSpuBoundsDTO smsSpuBoundsDTO) {
        boolean update = smsSpuBoundsService.addSpuBounds(smsSpuBoundsDTO);
        return update ? R.ok() : R.error();
    }
}
